<template>
	<view class="region">
		<!-- <view class="flex benben-position-layout flex flex-wrap align-center wrongQuestion_flex_0"
			:style="{height:(88+StatusBarRpx)+'rpx',paddingTop:StatusBarRpx+'rpx'}">
			<view class='flex flex-wrap align-center justify-between flex-sub wrongQuestion_fd0_0'>
				<view class='flex flex-wrap align-center' @tap.stop="handleJumpDiy" data-type="back" data-url="1">
					<text class='fu-iconfont2  wrongQuestion_fd0_0_c0_c0'>&#xE794;</text>
				</view>
				<text class='wrongQuestion_fd0_0_c1'>城市切换</text>
				<view class='flex flex-wrap align-center wrongQuestion_fd0_0_c2'>
				</view>
			</view>
		</view>
		<view :style="{height: (88+StatusBarRpx)+'rpx'}"></view> -->
		<view >
			<city-select @select="select"></city-select>
		</view>
	</view>
</template>

<script>
	import citySelect from "../components/t-index-address/t-index-address.vue"
	export default {
		data() {
			return {
				scrollTop: 0,
				indexList: [],
				city: '',
				isShowLoading: true,
				//需要构建索引参数的名称（注意：传递的对象里面必须要有这个名称的参数）
				formatName: 'city_name',
				//当前城市
				activeCity: {
					id: 1,
					city_name: '武汉'
				},
				//热门城市
				hotCity: [],
				//显示的城市数据
				obtainCitys: [],
				type: 1,  // 1选择城市  2选择城市内位置
			}
		},
		components: {
			citySelect
		},
		onPageScroll(e) {
			this.scrollTop = e.scrollTop;
		},
		onLoad(options) {
		},
		onShow() {
			if (uni.getStorageSync('city')) {
				console.log(uni.getStorageSync('city'));
			}
			// this.activeCity.lat = uni.getStorageSync('defaultCity').latitude;
			// this.activeCity.lng = uni.getStorageSync('defaultCity').longitude;
		},
		methods: {
			select(e) {
				let cityName = e.name + '市';
				uni.redirectTo({
					url: '/pages/index/select-regoin/select-districts?cityName=' + cityName
				})
			}
		}
	}
</script>

<style lang="scss" scoped>
	page {
		background-color: #FFFFFF !important;
	}
	.region {
		height: 100vh;
		background-color: #FFFFFF !important;
		.current {
			padding: 32rpx;
			background: #F5F6F7;

			.current-city {
				font-size: 28rpx;
				color: #666666;
				margin-bottom: 32rpx;
			}

			.city {
				padding: 10rpx 38rpx;
				background: #FFFFFF;
				display: inline-block;
				border-radius: 4rpx;

				image {
					width: 20rpx;
					height: 24rpx;
					vertical-align: middle;
					margin-right: 8rpx;
				}

				text {
					font-size: 24rpx;
				}
			}
		}

		.city-list {
			.list-cell {
				display: flex;
				box-sizing: border-box;
				width: 100%;
				padding: 10px 24rpx;
				overflow: hidden;
				color: #323233;
				font-size: 14px;
				line-height: 24px;
				background-color: #fff;
			}
		}

	}
	.wrongQuestion_fd0_0 {
		padding: 0rpx 32rpx 0rpx 32rpx;
		height: 88rpx;
	}
	
	.wrongQuestion_fd0_0_c0_c0 {
		font-size: 32rpx;
		font-weight: 500;
		color: #111;
	}
	
	.wrongQuestion_fd0_0_c1 {
		font-size: 32rpx;
		font-weight: bold;
		color: #111;
	}
	
	.wrongQuestion_fd0_0_c2 {
		width: 36rpx;
		height: 36rpx;
	}
	
	.wrongQuestion_flex_0 {
		// background: url(https://app.ezsdcsm.com/images/23.png) no-repeat, transparent;
		width: 750rpx;
		height: 88rpx;
		overflow: hidden;
		z-index: 10;
		top: 0rpx;
		background-size: 100% auto !important;
		background-color: #fff;
	}
</style>
